/*
 * @Author: chris
 * @Date: 2022-01-25 11:20:12
 * @LastEditors: chris
 * @LastEditTime: 2022-01-25 13:37:47
 * @FilePath: \midway-project\src\controller\user.ts
 */
import { Controller, Get, Inject, Query } from '@midwayjs/decorator';
import { Context } from '@midwayjs/koa';

@Controller('/api/user')
export class UserController {
  @Inject()
  ctx: Context;

  @Get('/')
  async getUser(@Query('id') id: string): Promise<object> {
    const query = this.ctx.query;
    return query;
  }
}
